Hearing device and method of hearing device communication

ABSTRACT

A hearing device includes: a processing unit configured to compensate for hearing loss of a user of the hearing device; a memory unit; and an interface; wherein the processing unit is configured to: receive a connection request for a session via the interface; obtain a session identifier; transmit, via the interface, a connection response comprising a hearing device identifier and the session identifier; receive, via the interface, an authentication message comprising an authentication key identifier and client device data; select a hearing device key from a plurality of hearing device keys in the memory unit based on the authentication key identifier; and verify the client device data based on the selected hearing device key.

RELATED APPLICATION DATA

This application claims priority to and the benefit of Danish PatentApplication No. PA 2015 70434 filed on Jul. 2, 2015, pending, andEuropean Patent Application No. 15175138.5 filed on Jul. 2, 2015,pending. The entire disclosures of the above applications are expresslyincorporated by reference herein.

FIELD

The present disclosure pertains to the field of hearing devices, and inparticular to hearing device security. Hearing device and method forsecure hearing device communication is disclosed.

BACKGROUND

Functionalities of a hearing device become increasingly advanced.Wireless communications between a hearing device and external devices,such as hearing device fitting apparatus, tablets, smart phones andremote controllers, have evolved. A wireless communication interface ofa hearing device uses an open standard-based interface. However, thisposes many challenges in terms of security. A hearing device may assumeany incoming data as legitimate, and may allow memory to be written orchanged by an unauthorized party. Any such attacks may result in amalfunction of the hearing aid, or a battery exhaustion attack.

However a hearing device is a very small device with strict constraintsin terms of computational power, memory space etc. Off-the-shelfsecurity algorithms and protocols cannot be readily functional on ahearing device.

SUMMARY

There is a need for methods and hearing devices providing improvedsecurity.

Disclosed is a hearing device. The hearing device comprises a processingunit, a memory unit and an interface. The hearing device may comprise aprocessing unit configured to compensate for hearing loss of a user ofthe hearing device. The processing unit is configured to receive aconnection request for a session via the interface; and to obtain asession identifier. The processing unit may be configured to transmitvia the interface a connection response comprising a hearing deviceidentifier and the session identifier. The processing unit is configuredto receive, via the interface, an authentication message. Theauthentication message may comprise an authentication key identifierand/or client device data. The processing unit may be configured toselect a hearing device key from a plurality of hearing device keys inthe memory unit, e.g. based on the authentication key identifier. Theprocessing unit may be configured to verify the client device data, e.g.based on the selected hearing device key or a default hearing devicekey; and to terminate the session if verification fails.

Also disclosed is a method of operating a hearing device. The hearingdevice comprises a processing unit configured to compensate for hearingloss of a user of the hearing device, a memory unit, and an interface.The method comprises receiving a connection request for a session viathe interface. The method comprises obtaining a session identifier. Themethod may comprise transmitting via the interface a connection responsecomprising a hearing device identifier and/or the session identifier.The method comprises receiving, via the interface, an authenticationmessage. The authentication message comprises an authentication keyidentifier and/or client device data. The method may comprise selectinga hearing device key from a plurality of hearing device keys in thememory unit, e.g. based on the authentication key identifier. The methodmay comprise verifying the client device data, e.g. based on theselected hearing device key or a default hearing device key, andterminating the session if verification fails.

The disclosed hearing device and method provides that the hearing deviceis capable of securing access thereto from unauthenticated parties, andsecuring its communication against eavesdropping, modification attacksand replay attacks while minimizing computational overhead and powerconsumption of the hearing device. This disclosure provides a hearingdevice the ability to perform various levels of authentication of acommunicating party and received message as well as to derive keyingmaterial for securing communication against eavesdropping with nosecrets exchanged in plain text. This disclosure provides a hearingdevice that supports authentication and/or confidentiality of itscommunications. Furthermore, the present disclosure provides a scalablesecurity architecture.

A hearing device includes: a processing unit configured to compensatefor hearing loss of a user of the hearing device; a memory unit; and aninterface; wherein the processing unit is configured to: receive aconnection request for a session via the interface; obtain a sessionidentifier; transmit, via the interface, a connection responsecomprising a hearing device identifier and the session identifier;receive, via the interface, an authentication message comprising anauthentication key identifier and client device data; select a hearingdevice key from a plurality of hearing device keys in the memory unitbased on the authentication key identifier; and verify the client devicedata based on the selected hearing device key.

Optionally, the session identifier is for a session, and wherein theprocessing unit is configured to terminate the session if a verificationof the client device data fails.

Optionally, the authentication message comprises an authentication typeidentifier, and wherein the processing unit is configured to select thehearing device key from the plurality of hearing device keys based onthe authentication type identifier.

Optionally, the client device data comprises an encrypted client devicecertificate; wherein the processing unit is configured to generate acertificate key based on a common secret; and wherein the processingunit is configured to verify the client device data by decrypting theencrypted client device certificate with the certificate key to obtain adecrypted version of the encrypted client device certificate.

Optionally, the common secret is based on the selected hearing devicekey and/or the session identifier.

Optionally, the processing unit is configured to verify the clientdevice data by determining whether the authentication key identifiermatches a client device key identifier of the client device certificate.

Optionally, the processing unit is configured to verify the clientdevice data by determining whether a client device type identifier ofthe client device certificate is valid.

Optionally, the processing unit is configured to verify the clientdevice data by verifying a digital signature of the client devicecertificate.

Optionally, the client device certificate comprises a signing deviceidentifier and/or a client device identifier, and wherein the processingunit is configured to verify the client device data by determiningwhether the signing device identifier and/or the client deviceidentifier is valid.

Optionally, the processing unit is configured to generate a session keybased on the session identifier and the hearing device key, and whereinthe processing unit is configured to receive and authenticate sessiondata based on the session key.

A method of operating a hearing device comprising a processing unitconfigured to compensate for hearing loss of a user of the hearingdevice, a memory unit, and an interface, the method includes: receivinga connection request for a session via the interface; obtaining asession identifier; transmitting, via the interface, a connectionresponse comprising a hearing device identifier and the sessionidentifier; receiving, via the interface, an authentication messagecomprising an authentication key identifier and client device data;selecting a hearing device key from a plurality of hearing device keysbased on the authentication key identifier; and verifying the clientdevice data based on the selected hearing device key.

Other features, advantageous, and/or embodiments will be described belowin the detailed description.

BRIEF DESCRIPTION OF THE DRAWINGS

The above and other features and advantages will become readily apparentto those skilled in the art by the following detailed description ofexemplary embodiments thereof with reference to the attached drawings,in which:

FIG. 1 schematically illustrates an exemplary architecture according tothis disclosure,

FIG. 2 schematically illustrates an exemplary hearing device,

FIG. 3A schematically illustrates an exemplary client devicecertificate,

FIG. 3B schematically illustrates an exemplary hearing devicecertificate,

FIG. 4 schematically illustrates an exemplary signaling diagram, and

FIG. 5 schematically illustrates a flowchart of an exemplary method.

DETAILED DESCRIPTION

Various embodiments are described hereinafter with reference to thefigures. Like reference numerals refer to like elements throughout. Likeelements will, thus, not be described in detail with respect to thedescription of each figure. It should also be noted that the figures areonly intended to facilitate the description of the embodiments. They arenot intended as an exhaustive description of the claimed invention or asa limitation on the scope of the claimed invention. In addition, anillustrated embodiment needs not have all the aspects or advantagesshown. An aspect or an advantage described in conjunction with aparticular embodiment is not necessarily limited to that embodiment andcan be practiced in any other embodiments even if not so illustrated, orif not so explicitly described.

Throughout, the same reference numerals are used for identical orcorresponding parts.

It is an object of the present disclosure to provide a hearing device,and a method of operating a hearing device which seeks to mitigate,alleviate, or eliminate one or more of the above-identified deficienciesin the art and disadvantages singly or in any combination.

The present disclosure relates to improved security of a hearing device.Namely, the hearing device disclosed herein is robust against securitythreats, vulnerabilities and attacks by implementing appropriatesafeguards and countermeasures, such as security mechanisms, to protectagainst threats and attacks. The present disclosure relates to a hearingdevice that is robust against replay attacks, unauthorized access,battery exhaustion attacks, eavesdropping and man-in-the-middle attacks.

As used herein, the term “hearing device” refers to a device configuredto assist a user in hearing a sound, such as a hearing instrument, ahearing aid device, a headset, a pair of headphones, etc.

As used herein, the term “certificate” refers to a data structure thatenables verification of its origin and content, such as verifying thelegitimacy and/or authenticity of its origin and content. Thecertificate is configured to provide a content that is associated to aholder of the certificate by an issuer of the certificate. Thecertificate comprises a digital signature, so that a recipient of thecertificate is able to verify or authenticate the certificate contentand origin. The certificate may comprise one or more identifiers and/orkeying material, such as one or more cryptographic keys (e.g. a hearingdevice key) enabling secure communication in a hearing device system.The certificate permits thus to achieve authentication of origin andcontent, non-repudiation, and/or integrity protection. The certificatemay further comprise a validity period, one or more algorithmparameters, and/or an issuer. A certificate may comprise a digitalcertificate, a public key certificate, an attribute certificate, and/oran authorization certificate.

As used herein, the term “key” refers to a cryptographic key, i.e. apiece of data, (e.g. a string, a parameter) that determines a functionaloutput of a cryptographic algorithm. For example, during encryption, thekey allows a transformation of a plaintext into a cipher-text and viceversa during decryption. The key may also be used to verify a digitalsignature and/or a message authentication code, MAC. A key is so calleda symmetric key when the same key is used for both encryption anddecryption. In asymmetric cryptography or public key cryptography, akeying material is a key pair, so called a private-public key paircomprising a public key and a private key. In an asymmetric or publickey cryptosystem (such as Rivest Shamir Adelman, RSA, cryptosystem, andelliptic curve cryptography, ECC), the public key is used for encryptionand/or signature verification while the private key is used fordecryption and/or signature generation. The hearing device key may bekeying material allowing deriving one or more symmetric keys, such as asession key and/or a certificate key for hearing device communication.The hearing device key may be stored in a memory unit of the hearingdevice, e.g. during manufacture. The hearing device key may comprisekeying material that is used to derive a symmetric key. The hearingdevice key comprises for example an Advanced Encryption Standard, AES,key, such as an AES-128 bits key.

As used herein the term “identifier” refers to a piece of data that isused for identifying, such as for categorizing, and/or uniquelyidentifying. The identifier may be in a form of a word, a number, aletter, a symbol, a list, an array or any combination thereof. Forexample, the identifier as a number may be in the form of an integer,such as unsigned integer, unit, with a length of e.g. 8 bits, 16 bits,32 bits, etc., such as an array of unsigned integers.

The term “client device” as used herein refers to a device that is ableto communicate with the hearing device. The client device may refer to acomputing device acting as a client. The client device may comprise afitting device, a handheld device, a relay, a tablet, a personalcomputer, a mobile phone, an application running on a personal computeror tablet, or mobile phone and/or USB dongle plugged into a personalcomputer. The client device may be attributed a client device typecorresponding to a model, category or type of client devices, such as afitting type, e.g. a tablet product model, category or type for fittingthe hearing device, a USB dongle product model, category or type forfitting the hearing device. The client device may control operation ofthe hearing device, either by sending fitting data, hearing deviceoperating parameters, and/or firmware data.

The present disclosure relates to a hearing device. The hearing devicecomprises a processing unit, a memory unit and an interface. The memoryunit may include removable and non-removable data storage unitsincluding, but not limited to, Read Only Memory (ROM), Random AccessMemory (RAM), etc. The memory unit may have a hearing device certificatestored thereon. The memory unit may have the hearing device certificatestored at a memory address of the memory unit, and/or in memory cells ofthe memory unit, such as in designated memory cells and/or at designatedaddresses. The hearing device may comprise a processing unit configuredto compensate for hearing loss of a user of the hearing device. Theinterface may comprise a wireless transceiver, e.g. configured forwireless communication at frequencies in the range from 2.4 to 2.5 GHz.In one or more exemplary hearing devices, the interface is configuredfor communication, such as wireless communication, with a client deviceor a hearing device, respectively comprising a wireless transceiverconfigured to receive and/or transmit data. The processing unit may beconfigured to compensate for hearing loss of a user of the hearingdevice according to the received data. The processing unit is configuredto receive a connection request for a session via the interface; andoptionally to obtain a session identifier, e.g. in response to theconnection request. The interface may be configured to receive theconnection request for a session from a client device. The processingunit is configured to obtain a session identifier, such as by generatinga random or pseudo-random number. The processing unit may be configuredto store the session identifier in the memory unit. The memory unit maybe configured to store the session identifier at a memory address of thememory unit, and/or in memory cells of the memory unit, such as indesignated memory cells and/or at designated addresses. The connectionrequest may comprise an authentication key identifier and/or anauthentication type identifier, in order to permit the hearing device toperform authentication of the connection request and the client devicesending the connection request at this early stage. This may provide alevel of access control.

The processing unit is configured to transmit via the interface aconnection response comprising a hearing device identifier and/or thesession identifier. The processing unit may be configured to generate aconnection response by including the session identifier and the hearingdevice identifier in the connection response. The hearing deviceidentifier may refer to a unique identifier of the hearing device. Thehearing device identifier may be included in the hearing devicecertificate. The interface may be configured to transmit the connectionresponse to e.g. the client device.

The processing unit is configured to receive, via the interface, anauthentication message comprising an authentication key identifierand/or client device data. For example, the interface may be configuredto receive the authentication message from the client device. Forexample the hearing device receives the authentication message from theclient device in order to establish a communication session. The clientdevice data may comprise a client device certificate (encrypted orunencrypted), fitting data, hearing device operating parameters, and/orfirmware data. For example, the authentication message may comprise anauthentication key identifier in plain text. The authentication keyidentifier may be indicative of a hearing device key, e.g. a hearingdevice key stored in the memory unit of the hearing device, for exampleas part of the hearing device certificate.

The processing unit is optionally configured to select a hearing devicekey, e.g. from a plurality of hearing device keys in the memory unit,based on the authentication key identifier and/or other identifiers.When the authentication key identifier is acceptable by the hearingdevice based on a hearing device key identifier held by the hearingdevice, the processing unit may be configured to select a hearing devicekey that the authentication key identifier indicates and to use theselected hearing device key as keying material in securing the session.The processing unit may be configured to select a hearing device key,e.g. from a plurality of hearing device keys in the memory unit based onthe authentication key identifier and/or an authentication typeidentifier. The authentication type identifier may be received inplaintext by the hearing device, and/or as client device type identifierin the client device certificate (encrypted or decrypted). For example,the processing unit may be configured to select a hearing device keywhich the authentication key identifier and the authentication typeidentifier indicate.

The processing unit is configured to verify the client device data, e.g.based on the selected hearing device key; and to terminate the sessionif verification fails. To verify the client device data may be based ona hearing device certificate or at least parts thereof. To verify theclient device data based on the selected hearing device key may compriseverifying the integrity of the client device data based on the selectedhearing device key, such as verifying a MAC and/or a digital signaturecomprised in the client device data. To verify the client device databased on the selected hearing device key may comprise decrypting theclient device data, e.g. a client device certificate, using the selectedhearing device key (as keying material to derive a decryption key or asa decryption key), when the client device data is received encrypted. Toverify the client device data based on the selected hearing device keymay comprise verifying the client device data, e.g. decrypted clientdevice certificate, by comparing the received client device data withdata stored in the memory unit. The client device data may comprise aclient device certificate (such as an encrypted client devicecertificate), an authentication key identifier, and/or an authenticationtype identifier. The client device may be assigned a client devicecertificate. The client device certificate refers to a certificategenerated and assigned to the client device by e.g. a devicemanufacturing the client device.

The client device certificate may comprise a certificate typeidentifier. The certificate type identifier may indicate a type of thecertificate amongst a variety of certificate types, such as a hearingdevice family certificate type, a hearing device certificate type, afirmware certificate type, a research and development certificate type,client device certificate type. The certificate type identifier may beused by the hearing device to identify what type of certificate itreceives, stores, and/or retrieves. The client device certificate maycomprise a version identifier indicative of a data format version of thecertificate. The hearing device may be configured to use the certificatetype identifier and/or the version identifier to determine what type ofdata the certificate comprises, what type of data is comprised in afield of the certificate. For example, the hearing device determinesbased on the certificate type identifier and/or version identifier whatfield of the certificate comprises a digital signature and/or whichpublic key is needed to verify the digital signature. It may beenvisaged that there is a one-to-one mapping between the certificatetype identifier and the public-private key pair.

The client device certificate may comprise a signing device identifier.The signing device identifier refers to a unique identifier identifyingthe device (such as a manufacturing device, e.g. an integrated circuitcard, a smart card, a hardware security module) that has signed theclient device certificate. The signing device identifier may for examplecomprise a medium access control, MAC, address of the signing deviceand/or a serial number. The signing device identifier optionally allowsfor example the hearing device to determine whether the signing deviceis e.g. black-listed or not, and thus to reject certificates signed by asigning device that is black-listed.

The client device certificate may comprise one or more hardwareidentifiers such as a first hardware identifier and/or a second hardwareidentifier. A hardware identifier may identify a piece of hardwarecomprised in the client device, such as a radio chip comprised in theclient device or a digital signal processor of the client device. Thehardware identifier may be stored in a register of the piece of hardwarecomprised in the hearing device during manufacturing of the piece ofhardware. The hardware identifier may comprise a serial number, a mediumaccess control, MAC, address, a chip identifier, or any combinationthereof. The client device certificate may comprise a client device typeidentifier. A client device type identifier may be indicative of a typewhich the client device belongs to. The client device may be attributeda client device type corresponding to a model, category or type ofclient devices, such as a fitting type, e.g. a tablet product model,category or type configured for fitting the hearing device, a USB dongleproduct model, category or type configured for fitting the hearingdevice.

The client device certificate may comprise a client device identifier.The client device identifier refers to an identifier identifying aclient device. The client device identifier may for example comprise amedium access control, MAC, address of the client device, and/or aserial number of the client device.

The client device certificate may comprise a client device keyidentifier. A client device key identifier may be indicative of theclient device key used as keying material for securing a communicationwith an external party, such as with a hearing device. In one or moreexemplary client device certificates, the client device certificatecomprises a Bluetooth address of the client device.

The client device certificate comprises a digital signature. The digitalsignature enables a proof or verification of authenticity of the hearingdevice certificate, such as verification of the signer legitimacy. Thedigital signature is optionally generated by the manufacturing deviceusing a client device fitting private key. The hearing device may beconfigured to verify the digital signature of the client devicecertificate when receiving the (encrypted or unencrypted) client devicecertificate comprising the digital signature (i.e. receiving theauthentication message comprising the encrypted client devicecertificate, and obtaining a decrypted version of the client devicecertificate). The digital signature is verifiable by the hearing deviceusing a corresponding client device fitting public key. If the digitalsignature is not successfully verified using the alleged public key, thehearing device may disregard the client device certificate and/or abortnormal operation. This may provide the advantage that the hearing devicerejects a client device certificate that is tampered or received fromunauthenticated parties. The communication with the hearing device maythus be robust against impersonation, modification and masqueradingattacks.

The authentication message may comprise an authentication typeidentifier. To select a hearing device key from a plurality of hearingdevice keys may be based on the authentication type identifier. Anauthentication type identifier may be indicative of a client device typeidentifier and/or a certificate type identifier, e.g. of the (encrypted)client device certificate. The client device may be attributed a clientdevice type corresponding to a model, category or type of clientdevices, such as a fitting type, e.g. a tablet product model, categoryor type configured for fitting the hearing device, a USB dongle productmodel, category or type configured for fitting the hearing device. Aclient device type identifier may refer to an identifier indicative of aclient device type. A client device type identifier may uniquelyidentify a client device type. A client device type identifier mayidentify a type which the client device belongs to. The client devicetype identifier may be comprised in the client device certificate. Thehearing device may be configured to select the hearing device keycorresponding to the authentication type identifier and/or theauthentication key identifier.

The client device data may comprise an encrypted client devicecertificate; and the processing unit may be configured to generate acertificate key based on the selected hearing device key and/or thesession identifier. To verify the client device data may comprise todecrypt the encrypted client device certificate with the certificate keyto obtain a decrypted version of the encrypted client devicecertificate. The encrypted client device certificate may be generated bythe client device using an encryption algorithm and a certificate key.

The hearing device may be configured to decrypt the encrypted clientdevice certificate using a certificate key, a common secret and/or ahearing device key. The certificate key may be based on a common secretand/or a certificate value. The hearing device may be configured toobtain and/or generate the common secret based on a hearing device key,such as the selected hearing device key. For example, to generate thecommon secret based on the hearing device key, the hearing device mayretrieve from the memory unit the hearing device key and/or the hearingdevice certificate from the memory unit, the hearing device certificatecomprising a hearing device key, which is to be used for derive thecommon secret. The hearing device may be configured to store the commonsecret in the memory unit, so as to e.g. retrieve the common secret fromthe memory unit when needed.

The hearing device may be configured to generate the common secret basedon a session identifier using the processing unit and to store thecommon secret in the memory unit. For example, the hearing device maygenerate a common secret based on a hearing device key, e.g. theselected hearing device key, and a session identifier. The hearingdevice may generate the common secret CS, e.g. as follows:

CS=hash(HD_KEY,S_ID),

where hash is a hash function, HD_KEY is the (selected) hearing devicekey and S_ID is a session identifier. The session identifier may begenerated by the hearing device upon reception of a connection request.The session identifier may comprise a random or pseudo random number ofa defined length. The common secret may be used as a certificate key inone or more exemplary hearing devices.

The certificate key may be based on the common secret, e.g. generated byperforming a hash function on the common secret and/or a certificatevalue. The hearing device may then generate the certificate key e.g. asfollows:

C_KEY=hash(CS,C_VAL),

where hash is a hash function, CS is the common secret and C_VAL is acertificate value. The certificate value may be a predefined value orstring, such as “certificate”.

In one or more exemplary hearing devices, the certificate key mayoptionally be generated by performing a hash function on the hearingdevice key and the session identifier. The hearing device may decryptthe encrypted client device certificate (part of the client device data)using the certificate key generated by the hearing device and obtain thedecrypted version of the client device certificate. The hearing devicemay verify the content of the decrypted version of the client devicecertificate.

In one or more exemplary hearing devices, to verify the client devicedata comprises to determine if the authentication key identifier matchesa client device key identifier of the client device certificate, andverification fails if no match is determined.

For example, the hearing device may be configured to verify that theauthentication key identifier matches a corresponding client device keyidentifier comprised in the client device certificate. For example, thehearing device may be configured to verify that the authentication keyidentifier has a value that is equal to the client device key identifiercomprised in the client device certificate. For example, the hearingdevice may be configured to verify that the authentication keyidentifier matches a corresponding client device key identifiercomprised in the decrypted version of the client device certificate.

In one or more exemplary hearing devices, to verify the client devicedata comprises to determine if a client device type identifier of theclient device certificate is valid and verification fails if the clientdevice type identifier of the client device certificate is not valid.For example, the hearing device may be configured to verify that theauthentication type identifier matches a corresponding client devicetype identifier comprised in the decrypted version of the client devicecertificate.

In one or more exemplary hearing devices, to determine if a clientdevice type identifier of the client device certificate is validcomprises to determine if the client device type identifier isblack-listed, wherein the client device type is not valid if the clientdevice type identifier is black-listed, e.g. appears on a list ofblack-listed client device types. In one or more exemplary hearingdevices, to determine if a client device type identifier of the clientdevice certificate is valid comprises to determine if the client devicetype identifier is allowed, wherein the client device type is valid ifthe client device type identifier is allowed, e.g. appears on a list ofallowed client device types. For example, the client device typeidentifier of the client device may be valid if the authentication typeidentifier matches a corresponding client device type identifiercomprised in the decrypted version of the client device certificate.

In one or more exemplary hearing devices, to verify the client devicedata comprises to verify a digital signature of the client devicecertificate, and verification fails if the digital signature is notverified. For example, the client device data comprises a digitalsignature appended to it to protect integrity of the client device data.Verifying a digital signature comprises e.g. computing a comparisonresult based on the digital signature and a corresponding client devicepublic key and comparing the comparison result to the received clientdevice data/client device certificate. The corresponding client devicepublic key may be retrieved by the hearing device from the memory unit,a remote data storage unit, and/or the server device. The digitalsignature may be verified as valid, or the verification is successfulwhen the digital signature raised to the power of the client devicepublic key is identical to the received client device data.

In one or more exemplary hearing devices, the client device certificatecomprises a signing device identifier and/or a client device identifier.The client device identifier refers to an identifier identifying aclient device. The client device identifier may for example comprise amedium access control, MAC, address of the client device, and/or aserial number of the client device. The hearing device may be configuredto verify the client device data by determining if the signing deviceidentifier and/or the client device identifier are valid. For example,the hearing device may be configured to determine if the signing deviceidentifier is valid by verifying that the signing device identifier isnot black-listed. For example, the hearing device may be configured todetermine if the client device identifier is valid by verifying that theclient device identifier is not black-listed. The client deviceidentifier allows for example the hearing device to identify the clientdevice amongst a plurality of client devices. Verification fails if thesigning device identifier and/or the client device identifier are notvalid. For example, if the hearing device determines that the signingdevice identifier and/or the client device identifier are black-listed,the signing device identifier and/or the client device identifier arenot valid and verification fails.

In one or more exemplary hearing devices, the processing unit isconfigured to receive an additional authentication message. Theadditional authentication message may comprise client device data and/oran authentication device identifier. The authentication deviceidentifier may refer to an identifier enabling authentication of theclient device, such as a client device identifier comprised in anauthentication message. For example, the authentication deviceidentifier comprises a serial number, a medium access control, MAC,address, or any combination thereof. The hearing device may beconfigured to verify the authentication message and authenticate theclient device sending the authentication message. The processing unitmay be configured to obtain a common secret based on the authenticationdevice identifier from the memory unit. The memory unit may have clientdevice identifiers associated with common secrets stored thereon. Theprocessing unit may then be configured to retrieve the correspondingcommon secret based on the authentication device identifier. The commonsecret has been generated and stored earlier at e.g. an initial round ofauthentication of a returning client device. Thus, once the clientdevice authenticated, the processing unit can just retrieve thecorresponding common secret. This provides a faster subsequentauthentication, and avoids having to regenerate the common secret forcomputing the additional certificate key, and thus saves thecorresponding power consumption. The processing unit may be configuredto generate an additional certificate key from the common secret; and toverify the client device data based on the additional certificate key.For example, the processing unit may generate the additional certificatekey by computing a hash value based on the common secret and acertificate value. As described above, the processing unit may beconfigured to verify the client device data based on the additionalcertificate key by verifying the integrity of the client device data,such as verifying a MAC and/or a digital signature of the client devicedata. The processing unit is configured to verify the client device databased on the additional certificate key by decrypting the client devicedata using the additional certificate key (as a decryption key), whenthe client device data is received encrypted. The processing unit isconfigured to verify the client device data by verifying the content ofthe client device data. The processing unit may be configured to verifythe client device data based on the additional certificate key bycomparing the client device data with data stored in the memory unit.

In one or more exemplary hearing devices, the processing unit isconfigured to generate an offline session key based on the common secretand the session identifier, and the processing unit is configured tocommunicate with the client device using the offline session key. Anoffline session key may be used to secure offline communication betweenthe hearing device and a client device. Offline communication refers toa communication that does not involve any other network device (e.g. aserver device). To generate an offline session key may comprise togenerate an offline key based on the common secret (e.g. perform a hashfunction of the common secret and an offline value), and to compute theoffline session key based on the offline key and the session identifier(e.g. perform a hash function of the offline key and the sessionidentifier). The offline session key is used by the hearing device andthe client device to secure (e.g. encrypt) the hearing device datacommunicated between the hearing device and the client device.

In one or more exemplary hearing devices, the authentication messagecomprises an authentication token identifier, and the processing unit isconfigured to store the authentication token identifier in the memoryunit and to link the authentication token identifier with the commonsecret. The authentication token identifier may be indicative ofenabling a token-based authentication at the hearing device, i.e. whenthe hearing device receives an authentication token identifier from anauthenticated client device, it may enable token-based authentication infuture communication with the same client device by storing e.g. anindicator such as a flag in relation with the common secret and theclient. For example, the hearing device receiving the authenticationtoken identifier may be configured to indicate to the processing unit toenable token-based authentication by storing and/or linking the tokenidentifier with the common secret generated for the same client device,such as by storing and/or linking the token identifier with the commonsecret and the client device identifier of the same client device ine.g. a table. Token identifiers and token-based authentication may beused for hearing device management, such as to group hearing deviceswithin a clinic or shop, and permit further fitting with minimal or nouser physical interaction/intervention as well as possibly simpler andfaster client device authentication. The client device for exampleaccesses securely a data storage where the token identifier is securelystored in a first session, retrieves the credential and keying materialto perform token-based authentication in a subsequent session. This way,any client device in e.g. a clinic or shop can be used to performfitting in a secure way using token-based authentication.

In one or more exemplary hearing devices, the processing unit isconfigured to receive a further authentication message comprising clientdevice data, an authentication type identifier, an authentication keyidentifier and/or an authentication session token identifier. Thefurther authentication message may comprise an authentication deviceidentifier. The processing unit may be configured to find in the memoryunit the common secret linked to the client device type identifierand/or the client device identifier of the client device that sends thefurther authentication message based on locating the stored clientdevice type identifier corresponding to the authentication typeidentifier and/or locating the stored client device identifiercorresponding to the authentication device identifier. The processingunit may be configured to obtain a common secret based on theauthentication type identifier; to generate a token key based on thecommon secret; and to generate a session token identifier based on thetoken key and the session identifier. The processing unit may havegenerated in an earlier session with the client device a common secretto e.g. establish a certificate key and may have stored and linked thecommon secret to the client device type identifier and/or the clientdevice identifier. The processing unit may then be configured to obtainthe common secret based on the authentication type identifier and/or theauthentication client identifier corresponding to the stored clientdevice type identifier and/or client device identifier. The processingunit may be configured to generate a token key by performing a hashfunction on the common secret and a token value (such as a pre-definedarbitrary string or a pre-defined arbitrary value). The processing unitmay be configured to generate a session token identifier based on thetoken key and the session identifier by generating a session identifier,and by performing a hash function on the token key and the sessionidentifier. The processing unit may be configured to verify theauthentication session token identifier based on the session tokenidentifier. The processing unit may be configured to verify theauthentication session token identifier by comparing the authenticationsession token identifier and the generated session token identifier. Forexample, if the processing unit determines that the authenticationsession token identifier matches the generated session token identifier,the verification is successful and the processing unit may proceed withno user physical intervention, and continue to verify the client devicedata provided in the further authentication message. The client devicedata may comprise a client device certificate. The hearing device mayverify the client device certificate (and/or check against a blacklist)for any fitting to be allowed. The verified authentication tokenidentifier may for example be used to indicate to the hearing devicethat the client device holds the previous shared token key and thereforeis allowed to fit exactly this hearing device without physical hearingdevice user intervention.

In one or more exemplary hearing devices, the processing unit isconfigured to generate a session key based on the session identifier andthe hearing device key, and the processing unit is configured to receiveand authenticate session data based on the session key. To generate asession key based on the session identifier and the hearing device keymay comprise computing the session key by generating a common secretbased on the hearing device key and the session identifier andoptionally generating a hash value of the common secret and a sessionvalue, the generated hash value corresponding to the session key. Forexample, the processing unit is configured to authenticate session databased on the session key by verifying a MAC generated with the sessionkey and/or by decrypting session data using the session key.

The present disclosure relates to a method of operating a hearing devicecomprising a processing unit configured to compensate for hearing lossof a user of the hearing device, a memory unit, and an interface, suchas a method for controlling communication of a hearing device, such as amethod for enabling secure hearing device communication. The methodcomprises receiving a connection request for a session via theinterface. The connection request may comprise an authentication keyidentifier and/or an authentication type identifier, in order to permitthe hearing device to perform authentication at this early stage theconnection request and the client device sending the connection request.This may provide a level of access control.

The method comprises obtaining a session identifier, e.g. with thehearing device. Obtaining a session identifier may comprise generating asession identifier, such as by generating a random or pseudo-randomnumber. For example, the processing unit generates a random orpseudo-random number of a predetermined length, e.g. 16 bytes, 32 bytes,64 bytes etc., to be used as a session identifier. Obtaining a sessionidentifier may comprise retrieving a session identifier from the memoryunit. The method may comprise storing the session identifier in thememory unit. For example, storing the session identifier in the memoryunit comprises storing the session identifier at a memory address of thememory unit, and/or in memory cells of the memory unit, such as indesignated memory cells and/or at designated addresses.

The method comprises transmitting via the interface a connectionresponse comprising a hearing device identifier and the sessionidentifier. Transmitting the connection response may comprise generatingthe connection response by including the session identifier and thehearing device identifier and transmitting the thus generated connectionresponse to e.g. the client device.

The method comprises receiving, via the interface, an authenticationmessage. The authentication message may comprise an authentication keyidentifier and/or client device data. The method may comprise receiving,via the interface, an authentication message from a client device. Forexample the hearing device receives the authentication message from theclient device in order to establish a communication session. The clientdevice data may comprise a client device certificate, fitting data,hearing device operating parameters, and/or firmware data. Theauthentication key identifier may be an identifier that may be used toverify if the client device provides an authentication key identifieracceptable by the hearing device.

The method comprises selecting a hearing device key from a plurality ofhearing device keys in the memory unit, e.g. based on the authenticationkey identifier. When the authentication key identifier matches thehearing device key identifier held by the hearing device and/or isindicative of a hearing device key of the hearing device, the processingunit may be configured to use the authentication key identifier as a keyidentifier indicating which hearing device key is to be used as keyingmaterial in the session. Selecting a hearing device key from a pluralityof hearing device keys in the memory unit may be based on theauthentication key identifier and/or an authentication type identifier.The authentication type identifier may be received in plaintext by thehearing device, and/or as client device type identifier in the clientcertificate (encrypted or decrypted). For example, the processing unitselects a hearing device key which the authentication key identifier andthe authentication type identifier indicate.

The method comprises verifying the client device data, e.g. based on theselected hearing device key. Verifying the client device data may bebased on a hearing device certificate or at least parts thereof.Further, the method may comprise terminating the session if verificationfails. Verifying the client device data based on the selected hearingdevice key may comprise verifying the integrity of the client devicedata based on the selected hearing device key, such as verifying a MACand/or a digital signature comprised in the client device data.Verifying the client device data based on the selected hearing devicekey may comprise decrypting the client device data using the selectedhearing device key (as keying material to derive a decryption key or asa decryption key), when the client device data is received encrypted.Verifying the client device data based on the selected hearing devicekey may comprise verifying the client device data by comparing thereceived client device data, e.g. decrypted client device certificate,with data stored in the memory unit. For example, verification fails ifintegrity of the client device data is detected as corrupted by e.g.verifying a MAC or a digital signature, if decryption fails, and/or ifcomparison of the received client device data with data stored in thememory unit shows a mismatch.

The authentication message optionally comprises an authentication typeidentifier. An authentication type identifier may be indicative of aclient device type identifier and/or a certificate type identifier.Selecting a hearing device key from a plurality of hearing device keysmay be based on the authentication type identifier. Selecting thehearing device key may be based on the authentication type identifierprovided in the authentication message and/or the authentication keyidentifier verified.

The client device data may comprise a client device certificate (such asan encrypted client device certificate), an authentication keyidentifier, and/or an authentication type identifier. The client devicemay be assigned a client device certificate.

The method may comprise generating a certificate key based on theselected hearing device key and/or the session identifier; and verifyingthe client device data may comprise decrypting the encrypted clientdevice certificate with the certificate key to obtain a decryptedversion of the encrypted client device certificate. Decrypting theencrypted client device certificate with the certificate key maycomprise decrypting the encrypted client device certificate using acertificate key, a common secret and/or a hearing device key, such asgenerating a certificate key based on a common secret, and processingthe encrypted client certificate using a decryption function and acertificate key. The certificate key may be based on a common secretand/or a certificate value. Generating a certificate key may compriseobtaining or generating the common secret based on the selected hearingdevice key. For example, generating the common secret based on thehearing device key comprises retrieving the hearing device certificatefrom the memory unit, the hearing device certificate comprising theselected hearing device key, and/or retrieving the selected hearingdevice key from the memory unit. The method may comprise generating thecommon secret based on a session identifier and/or the hearing devicekey. For example, the common secret CS is generated based on a selectedhearing device key and a session identifier, e.g. as follows:

CS=hash(HD_KEY,S_ID),

where hash is a hash function, HD_KEY is the selected hearing device keyand S_ID is a session identifier. The session identifier may comprise arandom or pseudo random number of a defined length. The common secretmay be used as a certificate key in one or more exemplary hearingdevices. The hearing device may be configured to store the common secretin the memory unit, so as to e.g. retrieve the common secret from thememory unit when needed.

Generating a certificate key may comprise performing a hash function onthe common secret and/or a certificate value. The hearing device maythen generate the certificate key e.g. as follows:

C_KEY=hash(CS,C_VAL),

where hash is a hash function, CS is the common secret and C_VAL is acertificate value. The certificate value may be a predefined value orstring, such as “certificate”.

In one or more exemplary methods, generating a certificate key comprisesperforming a hash function on the hearing device key and the sessionidentifier. Stated differently, the common secret may be used as acertificate key if the client device has also used the common secret ascertificate key to encrypt the client device certificate.

Verifying the client device data may comprise decrypting the encryptedclient device certificate using the certificate key generated by thehearing device and obtaining the decrypted version of the client devicecertificate.

In one or more exemplary methods, verifying the client device data maycomprise verifying a content of the decrypted version of the clientdevice certificate. For example, verifying the client device datacomprises determining if the authentication key identifier matches aclient device key identifier of the client device certificate, andverification fails if no match is determined.

In one or more exemplary methods, verifying the client device datacomprises determining if a client device type identifier of the clientdevice certificate is valid and verification fails if the client devicetype identifier of the client device is not valid. For example, anauthentication type identifier is sent in plain text in theauthentication message, the authentication type identifier sent in plaintext is valid if the authentication type identifier matches acorresponding client device type identifier comprised in the decryptedversion of the client device certificate. For example, determining if aclient device type identifier of the client device certificate is validmay comprise determining if the client device type identifier of theclient device certificate is comprised in a list of authorized clientdevices.

In one or more exemplary methods, determining if a client device typeidentifier of the client device certificate is valid comprisesdetermining if the client device type identifier is black-listed,wherein the client device type is not valid if the client device typeidentifier is black-listed, e.g. appears on a list of black-listedclient device types. In one or more exemplary methods, determining if aclient device type identifier of the client device certificate is validcomprises determining if the client device type identifier is allowed,wherein the client device type is valid if the client device typeidentifier is allowed, e.g. appears on a list of allowed or authorizedclient device types.

In one or more exemplary methods, verifying the client device datacomprises verifying a digital signature of the client devicecertificate, and verification fails if the digital signature is notverified. For example, the client device data comprises a digitalsignature appended to it to protect integrity of the client device data.Verifying a digital signature comprises e.g. computing a comparisonresult based on the digital signature and a corresponding public key andcomparing the comparison result to the received client device data. Thedigital signature may be verified as valid, or the verification may besuccessful when the digital signature raised to the power of the publickey is identical to the received client device data.

In one or more exemplary methods, the client device certificatecomprises a signing device identifier and/or a client device identifier,and verifying the client device data comprises determining if thesigning device identifier and/or the client device identifier is validand wherein verification fails if the client device identifier of theclient device and/or the signing device identifier is not valid.

In one or more exemplary methods, determining if a client deviceidentifier of the client device certificate is valid comprisesdetermining if the client device identifier is black-listed, wherein theclient device identifier is not valid if the client device identifier isblack-listed, e.g. appears on a list of black-listed client devices. Inone or more exemplary methods, determining if a client device identifierof the client device certificate is valid comprises determining if theclient device identifier is allowed, wherein the client device type isvalid if the client device identifier is allowed, e.g. appears on a listof allowed or authorized client devices.

In one or more exemplary methods, the method comprises receiving anadditional authentication message comprising client device data and/oran authentication device identifier. The method may further compriseobtaining, from the memory unit, a common secret based on theauthentication device identifier, generating an additional certificatekey from the common secret, and verifying the client device data basedon the additional certificate key.

In one or more exemplary methods, the method comprises generating anoffline session key based on the common secret and the sessionidentifier, and communicating with the client device using the offlinesession key.

In one or more exemplary methods, the method comprises receiving afurther authentication message comprising client device data, anauthentication type identifier, an authentication key identifier and/oran authentication session token identifier. The further authenticationmessage may comprise an authentication device identifier. The method maycomprise finding or determining in the memory unit the common secretlinked to the client device type identifier and/or the client deviceidentifier of the client device that sends the further authenticationmessage based on locating the stored client device type identifiercorresponding to the authentication type identifier and/or locating thestored client device identifier corresponding to the authenticationdevice identifier. The method may comprise obtaining a common secretbased on the authentication type identifier; generating a token keybased on the common secret; and generating a session token identifierbased on the token key and the session identifier. The processing unitmay have generated in an earlier session with the client device a commonsecret to e.g. establish a certificate key and may have stored andlinked the common secret to the client device type identifier and/or theclient device identifier. The method may comprise obtaining the commonsecret based on the authentication type identifier and/or theauthentication client identifier corresponding to the stored clientdevice type identifier and/or client device identifier. The method maycomprise generating a token key by performing a hash function on thecommon secret and a token value (such as a pre-defined arbitrary stringor a pre-defined arbitrary value). The method may comprise generating asession token identifier based on the token key and the sessionidentifier by generating a session identifier, and by performing a hashfunction on the token key and the session identifier. The method maycomprise verifying the authentication session token identifier based onthe session token identifier. The method may comprise verifying theauthentication session token identifier by comparing the authenticationsession token identifier and the generated session token identifier. Forexample, if it is determined that the authentication session tokenidentifier matches the generated session token identifier, theverification is successful and the processing unit may proceed with nouser physical intervention, and continue to verify the client devicedata provided in the further authentication message. The client devicedata may comprise a client device certificate. The hearing device mayverify the client device certificate (and check against a blacklist) forany fitting to be allowed. The verified authentication token identifiermay for example be used to indicate to the hearing device that theclient device holds the previous shared token key and therefore isallowed to fit exactly this hearing device without physical hearingdevice user intervention.

In one or more exemplary methods, the method comprises generating asession key based on the session identifier and the hearing device key,receiving and authenticating session data based on the session key.

FIG. 1 schematically illustrates exemplary devices that may be used formanufacturing, maintenance, and/or operating a hearing device 2. FIG. 1shows an exemplary system 1 and a hearing device 2. The system 1 maycomprise one or more of a manufacturing device 12, a client device 10,and a server device 16 for manufacturing, maintenance, and/or operatingthe hearing device 2 in connection with hearing loss compensation (suchas for fitting the hearing device, for updating a hearing deviceparameter).

The manufacturing device 12 may be configured to perform any steps ofthe method of manufacturing a hearing device. The manufacturing device12 may be configured to generate a hearing device certificate includingthe hearing device identifier and at least one of the generated hearingdevice keys. The manufacturing device 12 may be configured to transmitthe hearing device certificate to the hearing device. The manufacturingdevice 12 may comprise processing elements (such as a processor and amemory)

The hearing device 2 may be configured to compensate for hearing loss ofa user of the hearing device 2. The hearing device 2 may be configuredto communicate with the manufacturing device 12 using e.g. acommunication link 23, such as a uni or bi-directional communicationlink. The communication link 23 may be a wired link and/or wirelesscommunication link. The communication link 23 may be a single hopcommunication link or a multi-hop communication link. The wirelesscommunication link may be carried over a short-range communicationsystem, such as Bluetooth, Bluetooth low energy, IEEE 802.11, Zigbee.

The hearing device 2 may be configured to connect to the client device10 via a communication link 21, such as a bidirectional communicationlink. The communication link 21 may be a wired link and/or wirelesscommunication link. The communication link 21 may be a single hopcommunication link or a multi hop communication link. The wirelesscommunication link may be carried over a short-range communicationsystem, such as Bluetooth, Bluetooth low energy, IEEE 802.11, Zigbee.The hearing device 2 may be configured to connect to the client device10 over a network. The client device 10 may permit remote fitting of thehearing aid device where a dispenser connects to the hearing device viathe client device 10 of the user. The client device 10 may comprise acomputing device acting as a client, such as a fitting device 14 (e.g. ahandheld device, a relay, a tablet, a personal computer, a mobile phone,and/or USB dongle plugged in a personal computer). The processingunit/hearing device is configured to receive a connection request for asession via the interface; and to obtain a session identifier. Forexample, the interface of the hearing device 2 is configured to receivethe connection request from the client device 10 via communication link21. For example the hearing device 2 receives the connection requestfrom the client device 10 for establishing a communication session. Theprocessing unit of the hearing device is configured to transmit via theinterface a connection response comprising a hearing device identifierand/or the session identifier. The processing unit of the hearing deviceis configured to receive, via the interface, an authentication messagecomprising an authentication key identifier and/or client device data,e.g. from the client device 10 via communication link 21.

The client device 10 may be configured to communicate with the serverdevice 16 via a communication link 24, such as a bidirectionalcommunication link. The communication link 24 may be a wired link and/orwireless communication link. The communication link 24 may comprise anetwork, such as the Internet.

The client device 10 may be configured to communicate with the serverdevice 16 for maintenance, and update purposes. The server device 16 maycomprise a computing device configured to act as a server, i.e. to serverequests from the client device 10 and/or from the hearing device 2. Theserver device 16 may be controlled by the hearing device manufacturer.The server device 16 may be configured to communicate with themanufacturing device 12 via a communication link 22 for manufacturingmaintenance, and/or operational purposes. The server device 16 and themanufacturing device 12 may be co-located and/or form one entity formanufacturing maintenance, and/or operational purposes of the hearingdevice 2.

FIG. 2 schematically illustrates an exemplary hearing device 2. Thehearing device 2 comprises a processing unit 4, a memory unit 6 and aninterface 8. The hearing device 2 comprises a processing unit 4configured to compensate for hearing loss of a user of the hearingdevice 2. The interface 8 comprises a wireless transceiver, e.g.configured for wireless communication at frequencies in the range from2.4 to 2.5 GHz. The interface 8 is optionally configured forcommunication, such as wired and/or wireless communication, with amanufacturing device 12. The processing unit 4 may be configured tocompensate for hearing loss of a user of the hearing aid according todata received during manufacture and/or fitting. The hearing device 2optionally comprises a microphone 5 or a plurality of microphones forreceiving sound signal(s) and converting sound signal(s) into convertedsound signal. The converted sound signal may be an electrical and/ordigital version of the sound signal. The processing unit 4 is configuredto receive and process the converted sound signal into a processed soundsignal according to a hearing loss of a user of the hearing device 2.The processed sound signal may be compressed and/or amplified or thelike. The hearing device 2 comprises an output transducer/loudspeaker 7,known as a receiver. The receiver 7 is configured to receive theprocessed sound signal and convert it to an output sound signal forreception by an eardrum of the user.

The processing unit 4 is configured to receive a connection request fora session via the interface 8; and to obtain a session identifier.Hence, the processing unit 4 comprises e.g. an obtain unit 41 configuredto obtain a session identifier. Examples of an obtain unit 41 include arandom or pseudo-random number generator. The interface is configured toreceive the connection request for a session from a client device 10.The processing unit 4 is configured to obtain a session identifier, suchas by generating a random or pseudo-random number. The processing unit 4is configured to store the session identifier in the memory unit 6. Thememory unit 6 may be configured to store the session identifier at amemory address of the memory unit 6, and/or in memory cells of thememory unit 6, such as in designated memory cells and/or at designatedaddresses. The connection request may comprise an authentication keyidentifier and/or an authentication type identifier, in order to permitthe hearing device 2 to perform authentication at this early stage theconnection request and the client device 10 sending the connectionrequest. This may provide a level of access control.

The processing unit 4 is configured to transmit via the interface 8 aconnection response comprising a hearing device identifier and thesession identifier. The processing unit 4 may be configured to generatea connection response by including the session identifier and thehearing device identifier in the connection response. The hearing deviceidentifier may refer to a unique identifier of the hearing device 2,such as a serial number, a MAC address, and/or hardware identifier ofthe hearing device 2. The interface 8 is configured to transmit theconnection response to e.g. the client device 10.

The processing unit 4 is configured to receive, via the interface 8, anauthentication message comprising an authentication key identifier andclient device data. For example, the interface 8 may be configured toreceive the authentication message from the client device 10. Forexample the hearing device 2 receives the authentication message fromthe client device 10 in order to establish a communication session. Theclient device data may comprise a client device certificate (encryptedor unencrypted), fitting data, hearing device operating parameters,and/or firmware data. For example, the authentication message maycomprise an authentication key identifier in plain text. Theauthentication key identifier may be indicative of a hearing device key.The processing unit 4 that processes the authentication key identifieris configured to e.g. verify the authentication key identifier bycomparing it to the hearing device key identifier stored e.g. in thememory unit 6 and determining the authentication key identifier asacceptable if the authentication key identifier is for example equal orhigher than the hearing device key identifier stored.

The processing unit 4 is configured to select a hearing device key froma plurality of hearing device keys in the memory unit 6 based on theauthentication key identifier. Hence, the processing unit 4 comprisese.g. a select unit 42 configured to select a hearing device key based onthe authentication key identifier. When the authentication keyidentifier is acceptable by the hearing device 2 based on a hearingdevice key identifier held by the hearing device 2, the processing unit4 is configured to select a hearing device key that the authenticationkey identifier indicates and to use the selected hearing device key askeying material used to secure the session. Optionally, the processingunit 4 may be configured to select a hearing device key from a pluralityof hearing device keys in the memory unit 6 based on the authenticationkey identifier and an authentication type identifier. The authenticationtype identifier may be included in the authentication message andreceived in plaintext by the hearing device 2, and/or as client devicetype identifier in the client certificate (encrypted or decrypted). Forexample, the processing unit 4 may be configured to select a hearingdevice key that the authentication key identifier and the authenticationtype identifier indicate.

The processing unit 4 is configured to verify the client device databased on the selected hearing device key; and to terminate the sessionif verification fails. For example, the processing unit 4 is configuredto verify the client device data based on the selected hearing devicekey by verifying the integrity of the client device data based on theselected hearing device key, such as verifying a MAC and/or a digitalsignature of the client device data. The processing unit 4 is configuredto verify the client device data based on the selected hearing devicekey by decrypting the client device data using the selected hearingdevice key (as keying material to derive a decryption key or as adecryption key), when the client device data is received encrypted, andby verifying the content of the decrypted client device data. Theprocessing unit 4 may be configured to verify the client device databased on the selected hearing device key by comparing the decryptedclient device data with data stored in the memory unit 6. The clientdevice data may comprise a client device certificate (such as anencrypted client device certificate), an authentication key identifier,and/or an authentication type identifier. The client device 10 may beassigned a client device certificate. The client device certificaterefers to a certificate generated and assigned to the client device bye.g. a manufacturing device 12. Examples of client device certificatesare illustrated in FIG. 3A. The processing unit 4 may be configured togenerate a certificate key based on the selected hearing device keyand/or the session identifier. To verify the client device data maycomprise to decrypt the encrypted client device certificate with thecertificate key to obtain a decrypted version of the encrypted clientdevice certificate.

The processing unit 4 may be configured to verify the client device databy determining if the authentication key identifier matches a clientdevice key identifier of the (decrypted) client device certificate, andverification fails if no match is determined.

In one or more exemplary hearing devices, the processing unit 4 isconfigured to verify the client device data by determining if a clientdevice type identifier of the client device certificate is valid andverification fails if the client device type identifier of the clientdevice is not valid. The processing unit 4 is configured to verify theclient device data by verifying a digital signature of the client devicecertificate included in the client device data, and verification failsif the digital signature is not verified.

The processing unit 4 may be configured to verify the client device databy determining if the signing device identifier and/or the client deviceidentifier are valid, e.g. not black-listed.

In one or more exemplary hearing devices, the processing unit 4 isconfigured to generate an offline session key based on the common secretand the session identifier, and the processing unit 4 is configured tocommunicate with the client device using the offline session key.

In one or more exemplary hearing devices, the authentication message 421comprises an authentication token identifier, and the processing unit 4is configured to store the authentication token identifier in the memoryunit 6 and to link the authentication token identifier with the commonsecret. The authentication token identifier may be indicative ofenabling a token-based authentication at the hearing device 2, i.e. whenthe hearing device receives an authentication token identifier from anauthenticated client device 10, it may enable token-based authenticationin future communication with the same client device 10 by storing e.g.an indicator such as a flag in relation with the common secret and theclient device. For example, the hearing device 2 receiving theauthentication token identifier may be configured to indicate to theprocessing unit 4 to enable token-based authentication by storing and/orlinking the token identifier with the common secret generated for thesame client device 10, such as by storing and/or linking the tokenidentifier with the common secret and the client device identifier ofthe same client device in e.g. a table.

In the hearing device 2, the processing unit 4 is configured to generatea session key based on the session identifier and the hearing devicekey, and the processing unit 4 is configured to receive and authenticatesession data based on the session key.

In one or more exemplary hearing devices, the processing unit 4 isconfigured to receive an additional authentication message via theinterface 8. The additional authentication message comprises clientdevice data and an authentication device identifier. The processing unit4 may be configured to obtain a common secret based on theauthentication device identifier from the memory unit 6. The processingunit 4 may be configured to generate an additional certificate key fromthe common secret; and to verify the client device data based on theadditional certificate key.

FIG. 3A schematically illustrates an exemplary client device certificate106. The client device data may comprise a client device certificate 106and/or an encrypted client device certificate 106A. The client device 10may be assigned a client device certificate 106. The client devicecertificate 106 refers to a certificate generated and assigned to theclient device 10 by e.g. a manufacturing device 12. The encrypted clientdevice certificate 106A may be generated by the client device 10 usingan encryption algorithm and a certificate key.

The client device certificate 106 comprises a certificate typeidentifier 130A. The certificate type identifier 130A may indicate atype of the certificate amongst a variety of certificate types, such asa hearing device family certificate type, a hearing device certificatetype, a firmware certificate type, a research and developmentcertificate type, client device certificate type. The certificate typeidentifier 130A may be used by the hearing device 2 to identify whattype of certificate it receives, stores, and/or retrieves and to actaccordingly. The client device certificate 106 may comprise a versionidentifier 132 which indicates a data format version of the clientdevice certificate 106. The hearing device 2 may be configured to usethe certificate type identifier 130A and/or the version identifier 132to determine what type of data the certificate comprises, and/or whattype of data is comprised in a field of the certificate. For example,the hearing device 2 determines based on the certificate type identifier130A and/or version identifier 132 what field of the certificate 106comprises a digital signature 113A, and/or which public key is needed toverify the digital signature 113A. It may be envisaged that there is aone-to-one mapping between the certificate type identifier 130A and thepublic-private key pair. It may be envisaged that the hearing device 2obtains the corresponding public key, such as retrieves thecorresponding public key from the memory unit 6, a remote data storage,and/or receives the corresponding public key from the client device 10and/or a server device 16. The client device certificate 106 maycomprise a signing device identifier 136A. The signing device identifier136A refers to a unique identifier identifying the device (such as aclient device 10, a server device 16, an integrated circuit card, asmart card, and/or a hardware security module thereof) that has signedthe client device certificate 106, e.g. during manufacture of the clientdevice. The signing device identifier 136A may for example comprise amedium access control, MAC, address of the signing device, and/or aserial number of the signing device. The signing device identifier 136Aallows for example the hearing device 2 to determine whether the signingdevice is e.g. black listed or not, and thus to reject certificatessigned by a signing device that is black listed. The client devicecertificate 106 may comprise one or more hardware identifiers, such as afirst hardware identifier 148A, and a second hardware identifier 150.The hardware identifiers, 148A, 150 may identify a piece of hardwarecomprised in the client device 10, such as a radio chip comprised in theclient device 10, and/or a digital signal processor of the client device10. The hardware identifier (s) may be stored in a register of the pieceof hardware comprised in the hearing device during manufacturing of thepiece of hardware. The hardware identifier(s) may comprise a serialnumber, a medium access control, MAC, address, a chip identifier, or anycombination thereof.

In one or more exemplary client device certificates, the client devicecertificate 106 comprises a client device type identifier 156. A clientdevice type identifier 156 may be indicative of a type which the clientdevice belongs to. The client device certificate 106 may comprise aclient device identifier 158. The client device certificate may comprisea client device key identifier 159. A client device key identifier 159may be indicative of the client device key used as keying material forsecuring a communication with an external party.

In one or more exemplary client device certificates, the client devicecertificate 106 comprises a Bluetooth address 160 of the client device.

The client device certificate 106 comprises a digital signature 113A.The digital signature 113A enables a proof or verification ofauthenticity of the client device certificate, such as verification ofthe signer legitimacy. The digital signature 113A is optionallygenerated by the manufacturing device 12 using a client device fittingprivate key. The hearing device 2 may be configured to verify thedigital signature 113A when receiving the client device certificatecomprising the digital signature 113A (i.e. receiving the authenticationmessage comprising the encrypted client device certificate, andobtaining a decrypted version of the client device certificate 106B).The digital signature 113A is verifiable by the hearing device 2 using acorresponding client device fitting public key, which is e.g. stored inthe memory unit 6. If the digital signature 113A is not successfullyverified using the alleged public key, the hearing device 2 maydisregard the client device certificate 106 (and authentication message)and/or abort normal operation/the session. This may provide theadvantage that the hearing device 2 rejects a client device certificate106 (and authentication message) that is tampered or received fromunauthenticated parties. The communication with the hearing device 2 maythus be robust against impersonation, modification and masqueradingattacks.

FIG. 3B schematically illustrates an exemplary hearing devicecertificate 100. The hearing device certificate 100 comprises a hearingdevice identifier 112, at least one hearing device key identifierincluding a first hearing device key identifier 114 indicative of ahearing device key and one or a plurality of hearing device keys. Thehearing device identifier 112 may refer to a unique or a pseudo-uniqueidentifier. The first hearing device key identifier 114 is indicative ofthe first hearing device key(s) of the hearing device certificate. Forexample, the first hearing device key identifier 114 may be indicativeof or point to a hearing device key of a first set 115 of hearing devicekeys (115A, 1158, 115C, 115D) of the hearing device certificate, e.g.the first primary hearing device key 115A.

The hearing device certificate 100 optionally comprises at least foursets of hearing device keys enabling secure and distinct communicationwith at least four different client devices/client device types.

The hearing device certificate 100 comprises a first set 115 of hearingdevice keys including a first primary hearing device key 115A. The atleast one hearing device key identifier comprises a first hearing devicekey identifier 114 indicative of a hearing device key of the first set115 of hearing device keys 115A, 1158, 115C, 115D. The first set 115 ofhearing device keys comprises for example first primary key 115A, firstsecondary key 1158, first tertiary key 115C, and first quaternary key115D dedicated to securing communication to and from a first clientdevice or a first client device type. For example, the first set 115 ofhearing devices key may be a set of hearing device keys 115A, 1158,115C, 115D for securing communication of hearing device data with thefirst client device.

The plurality of hearing device keys may comprise a second set 117 ofhearing device keys including a second primary hearing device key 117A,a second secondary hearing device key 117B, a second tertiary hearingdevice key 117C, and/or a second quaternary hearing device key 117D. Theat least one hearing device key identifier comprises a second hearingdevice key identifier 116 indicative of a hearing device key of thesecond set 117 of hearing device keys 117A, 1178, 117C, 117D. Thehearing device is configured to communicate with one or more clientdevices, such as a first client device and/or a second client device.For each client device or client device type that the hearing device isconfigured to communicate with, the hearing device certificateoptionally comprises a set of hearing device keys configured to enablesecure communication with a specific client device or client devicetype, and a hearing device key identifier indicating which hearingdevice keys that are part of the hearing device certificate. The hearingdevice certificate may comprise a third set 119 of hearing device keysincluding a third primary hearing device key 119A, a third secondaryhearing device key 119B, a third tertiary hearing device key 119C,and/or a third quaternary hearing device key 119D. The at least onehearing device key identifier comprises a third hearing device keyidentifier 118 indicative of a hearing device key of the third set 119of hearing device keys. The hearing device certificate 100 may comprisea fourth set of hearing device keys including a fourth primary hearingdevice key (not shown). The at least one hearing device key identifiercomprises a fourth hearing device key identifier indicative of a hearingdevice key of the fourth set of hearing device keys. The hearing device2 may be configured to select a set of hearing device keys based on theclient device or the client device type connected to the hearing deviceand to select a hearing device key from the set of hearing device keysselected based on the hearing device key identifier associated with theselected set of hearing devices.

The hearing device certificate 100 optionally comprises a certificatetype identifier 130B. The certificate type identifier 130B indicatesthat the hearing device certificate 100 is a hearing device certificate,e.g. selected amongst a variety of certificate types, such as a hearingdevice family certificate type, a hearing device certificate type, afirmware certificate type, a research and development certificate type,and a client device certificate type. The certificate type identifier130B may be used to enable the hearing device 2 to identify what type ofcertificate it receives, stores, authenticates and/or retrieves. Thehearing device certificate 100 may comprise a version identifier whichindicates a data format version of the hearing device certificate. Thehearing device 2 may use the certificate type identifier 130B and/or theversion identifier to determine what type of data the hearing devicecertificate 100 comprises, what type of data is comprised in a field ofthe hearing device certificate 100. For example, the hearing device 2may determine based on the certificate type identifier 130B and/orversion identifier what field of the certificate comprises a digitalsignature 113B, and which public key is needed to verify the digitalsignature 113B. It may be envisaged that there is a one-to-one mappingbetween the certificate type identifier 130B and the public-private keypair used for generating the digital signature 113B. The hearing devicecertificate 100 may comprise a length identifier that indicates thelength of the hearing device certificate 100, e.g. in bits, bytes.

The hearing device certificate 100 optionally comprises a signing deviceidentifier 136B. The signing device identifier 136B refers to a uniqueidentifier identifying the device (such as a manufacturing device 12,e.g. an integrated circuit card, a smart card, a hardware securitymodule comprised in a manufacturing device 12) that has signed thehearing device certificate 100. The signing device identifier 136B mayfor example comprise a medium access control, MAC, address of thesigning device, a serial number. The signing device identifier 136Ballows for example the hearing device 2 to determine whether the signingdevice is e.g. black-listed or not, and thus to reject hearing devicecertificates 100 signed by a signing device that is black-listed.

The hearing device certificate 100 optionally comprises one or morehardware identifiers including a first hardware identifier 148B and/or asecond hardware identifier (not shown). The first hardware identifier148B may identify a piece of hardware comprised in the hearing device 2,such as a processing unit 4, a radio chip comprised in the hearingdevice 2, a digital signal processor of the hearing device 2. The firsthardware identifier 148B may also be stored in a register of the pieceof hardware comprised in the hearing device 2 during manufacturing ofthe piece of hardware. The first hardware identifier 148B may comprise aserial number, a medium access control, MAC, address, a chip identifier,or any combination thereof. The hearing device certificate 100 maycomprise a first hardware identifier 148B, a second hardware identifierand/or a third hardware identifier. For example, the first hardwareidentifier 148B may provide a first hearing device specific valuepresent in a register of a hardware module (e.g. the processing unit orthe radio chip) of the hearing device 2 while the second hardwareidentifier may provide a second hearing device specific value present ina register of a hardware module of the hearing device 2, and a thirdhardware identifier may provide a third hardware module identifier (e.g.a processing unit identifier, a DSP identifier). The hearing device 2,upon receiving the hearing device certificate 100 comprising the firsthardware identifier 148B, may then verify the hearing device certificate100 by comparing its stored hardware identifier and the first hardwareidentifier 148B comprised in the hearing device certificate 100received. This way, the hearing device 2 may determine if the receivedhearing device certificate is intended for the hearing device 2 andreject the received hearing device certificate if the stored andreceived hardware identifiers do not match.

The hearing device certificate 100 optionally comprises a client devicetype authorization identifier 144. A client device type may comprise amodel, category or type of client devices, such as a tablet productmodel, category or type, a USB dongle product model, category or type.The client device type authorization identifier 144 is an identifier ofan authorized client device type, such as an identifier of the clientdevice types that the hearing device 2 may authorize for communication,such as for fitting, maintenance and/or operation. The client devicetype authorization identifier 144 is for example a bit-field indicatingthe type of client device the hearing device 2 should allow for fitting.

The hearing device certificate 100 optionally comprises a tokenparameter 146. The token parameter 146 indicates whether a token-basedauthentication is to be enabled or not. For example, if the tokenparameter 146 is set to 0, token-based authentication of client devicesis not to be enabled by the hearing device 2 and the hearing device 2 isto use for example a combination of client device type identifier and/ora client device identifier (such as a serial number) to perform anauthentication of the client device 10. If for example the tokenparameter 146 is set to 1, token-based authentication of client devicesis to be enabled by the hearing device 2, i.e. the hearing device 2authenticates the client device 10 (such as a based on a token receivedfrom the client device 10). The hearing device 2 may also derive asession specific token based on the received token parameter 146 whichis used to e.g. accept the connection to the client device 10 withoutuser intervention.

The hearing device certificate 100 comprises one or more of a hardwareplatform identifier 138, a software platform identifier 140, and/or acertificate timestamp 142. The hardware platform identifier 138 mayidentify a hardware platform, such as an operational hearing devicehardware platform, i.e. a hardware platform on which the hearing devicecertificate may be used. The software platform identifier 140 mayidentify a family of software platforms on which the hearing devicecertificate is configured to operate. The certificate timestamp 142refers to a timestamp of production or manufacture of the hearing devicecertificate 100, such as a timestamp of the manufacturing device 12indicating a time instant when the hearing device certificate 100 hasbeen generated. The certificate timestamp 142 may be in form of e.g.:hour, min, date, month, year.

The hearing device certificate comprises a digital signature 113B and/ora MAC. The digital signature 113B enables a proof or verification ofauthenticity of the hearing device certificate 100, such as verificationof the signer legitimacy (e.g. whether the signer is a legitimatemanufacturing device). The digital signature 113B is generated by themanufacturing device 12 using a device family private key duringmanufacturing of the hearing device. The hearing device 2 or theprocessing unit 4 may then verify the digital signature 113B, e.g. whenreceiving the hearing device certificate 100 comprising the digitalsignature 113B. The digital signature 113B is verifiable by the hearingdevice 2 using a corresponding device family public key. If the digitalsignature 113B is not successfully verified using the alleged publickey, the hearing device may disregard the hearing device certificate 100and/or abort normal operation.

FIG. 4 schematically illustrates an exemplary signaling diagram 400involving a hearing device 2, and a client device 10. The client device10 may comprise a fitting device 14. The hearing device 2 receives viathe interface 8 a connection request or message 411 for session from theclient device 10. When the client device 10 comprises a fitting device14, the fitting device 14 may generate a connection request 410, whichis transmitted by the client device 10 as connection request 411. Thehearing device 2 obtains a session identifier 180, such as generates asession identifier 180. The hearing device 2 generates a connectionresponse 412 comprising a hearing device identifier 112 and/or a sessionidentifier 180 and transmits the connection response 412 to the clientdevice 10. When the client device 10 comprises a fitting device 14, thefitting device 10 may receive the connection response 412 via the clientdevice 10. The client device 10 generates an authentication message 421and transmits the authentication message 421 to the hearing device 2.The hearing device 2 receives the authentication message 421 from theclient device 10. The authentication message 421 comprises anauthentication key identifier 166, optional authentication typeidentifier 168, and client device data 109. The client device data 109comprises an encrypted client device certificate 106A or client devicecertificate 106. Any of client device type identifier 156, client deviceidentifier 158, and a user identifier may be comprised in the encryptedclient device certificate 106A. Any of a client device identifier, aclient device type identifier 156 and/or a user identifier may becomprised in the authentication message 421 in plain text, or as part of(plain) client device certificate 106. When the client device 10comprises a fitting device 14, the fitting device 14 may generate anauthentication message 420, which is transmitted by the client device 10as authentication message 421.

Optionally, the hearing device 2 is configured to authenticate theauthentication message 421 by verifying the content, origin and/orintegrity of the authentication message 421. For example, the hearingdevice 2 verifies whether the received value of authentication keyidentifier 166 received is higher or equal to a hearing device keyidentifier comprised in the hearing device certificate 100 (and/or thelatest value the hearing device 2 has stored as hearing device keyidentifier in e.g. a flash memory). If the hearing device 2 determinesthat the received value of authentication key identifier 166 received ishigher or equal to a hearing device key identifier, the authenticationcontinues, else the session is terminated immediately (with proper errorcode). This prevents the hearing device 2 to communicate with anexpired/revoked client device.

For example, the hearing device 2 determines the type of client devicebased on authentication type identifier. The hearing device 2 selects ahearing device key from a plurality of hearing device keys based on theauthentication type identifier 168 and/or the authentication keyidentifier 166. For example, the hearing device 2 identifies the hearingdevice key corresponding to the authentication key identifier 166received. The hearing device 2 uses the identified hearing device keyand the session identifier 180 (e.g. a 16 bytes of random number) sentin connection response 412 to the client device 10 to derive thecertificate key, such as to compute a common secret from which thecertificate key is derivable.

Using the certificate key, the hearing device 2 decrypts the encryptedclient device certificate 106A. The hearing device 2 may then verifythat the certificate type identifier 130A comprised in the decryptedclient device certificate 106B corresponds to the right certificate106B. The hearing device 2 may then verify that the authentication typeidentifier 168 received in plain text match the client device typeidentifier 156 in the decrypted certificate 106B. The hearing device 2may then verify that the authentication key identifier 166 received inplain text match the client device key identifier 159 in the decryptedcertificate 106B and may further assess if the authentication keyidentifier 166 and/or the client device key identifier 159 is indicativeof a hearing device key identifier (such as a first hearing device keyidentifier 114) held by the hearing device 2. The hearing device 2 maythen verify that the version identifier 132 in the decrypted certificate106B is supported by the hearing device 2. The hearing device 2 may thenverify that the authentication type identifier 168 received in plaintext or the client device type identifier 156 is listed in the clientdevice type authorization identifier 144 of the stored hearing devicecertificate 100. The hearing device 2 may then verify that theauthentication type identifier 168 received in plain text or the clientdevice type identifier 156 associated with the first hardware identifier148A, 150 is not black-listed. The signing device identifier 136A isverified not to be listed on the blacklist. The hearing device 2 maythen verify the digital signature 113A of the client device certificate106B using the matching public key.

Upon successful authentication of the authentication message 421 and/orverification, the hearing device 2 may send an authentication response422 to the client device 10 that may forward it to a fitting device 14when the client device 10 comprises the fitting device 14.

The communication channel is now open and secure. The client device 10or fitting device 14 via the client device 10 may send hearing devicedata 430 to the hearing device 2, such as hearing device data 430 in asession secured by a session key. Hearing device data 430 comprises e.g.firmware, fitting data, and/or hearing device operating parameters.Fitting data may for example be data generated by a fitting device 14used by a dispenser when a hearing device 2 is being fitted in a user'sear. Fitting data may comprise hearing loss parameters, compressorparameters, filter coefficients, and/or gain coefficients. Hearingdevice operation parameters may comprise volume control parameters, modeand/or program control parameters. Firmware may refer to a computerprogram provided by the hearing device manufacturer, and to be installedon the hearing device 2 to control the hearing device 2. Firmware is forexample to be installed to upgrade the operations and capabilities ofthe hearing device 2.

Optionally, for example when the client device 10 re-connects to thehearing device 2, the processing unit 4 may be configured to receive viathe interface 8 an additional authentication message 440. The additionalauthentication message 440 comprises client device data 110 and anauthentication device identifier 169. The processing unit 4 may beconfigured to verify the authentication message 440 and authenticate theclient device sending the authentication message 440. The processingunit 4 may be configured to obtain, from the memory unit 6, a commonsecret based on the authentication device identifier 169. The memoryunit 6 may have client device identifiers 158 associated withcorresponding common secrets stored thereon, for authenticated clientdevices 10. The processing unit 4 may then be configured to retrieve thecorresponding common secret based on the authentication deviceidentifier 169. The common secret has been generated and stored earlierat e.g. an initial round of authentication of a returning client device10. Thus, once the client device 10 authenticated, the processing unit 4can just retrieve the corresponding common secret from the memory unit6. This provides a faster subsequent authentication, and avoids havingto regenerate the common secret for computing the additional certificatekey, and thus saves the corresponding power consumption. The processingunit 4 may be configured to generate an additional certificate key fromthe common secret and to verify the client device data 110 based on theadditional certificate key. For example, the processing unit 4 generatesthe additional certificate key by computing a hash value based on thecommon secret and a certificate value. As described above, theprocessing unit 4 may be configured to verify the client device data 110based on the additional certificate key by verifying the integrity ofthe client device data 110, such as verifying a MAC and/or a digitalsignature of the client device data 110. The processing unit 4 isconfigured to verify the client device data 110 based on the additionalcertificate key by decrypting the client device data 110 using theadditional certificate key (as a decryption key), when the client devicedata 110 is received encrypted. The processing unit 4 is configured toverify the client device data 110 by verifying the content of the clientdevice data 110. The processing unit 4 may be configured to verify theclient device data by comparing the client device data 110 with datastored in the memory unit 6. The client device data 110 may comprise aclient device certificate 106, such as an encrypted client devicecertificate 106A.

Optionally, the processing unit 4 is configured to receive a furtherauthentication message 450 comprising client device data 110 and anauthentication token identifier 167. The processing unit 4 is configuredto obtain a common secret based on the authentication token identifier167 from the memory unit 6; to generate a token key from the commonsecret.

In one or more exemplary hearing devices, the processing unit 4 isconfigured to receive a further authentication message 450 comprisingclient device data 110, an authentication type identifier 168, anauthentication key identifier 166 and/or an authentication session tokenidentifier 167. The further authentication message may comprise anauthentication device identifier 169. The processing unit 4 may beconfigured to find in the memory unit 6 the common secret linked to theclient device type identifier and/or the client device identifier of theclient device 10 that sends the further authentication message 450 basedon locating the stored client device type identifier corresponding tothe authentication type identifier 168 and/or locating the stored clientdevice identifier corresponding to the authentication device identifier169. The processing unit 4 may be configured to obtain a common secretbased on the authentication type identifier 168; to generate a token keybased on the common secret; and to generate a session token identifierbased on the token key and the session identifier. The processing unit 4may have generated in an earlier session with the client device 10 acommon secret to e.g. establish a certificate key and may have storedand linked the common secret to the client device type identifier and/orthe client device identifier. The processing unit 4 may then beconfigured to obtain the common secret based on the authentication typeidentifier 168 and/or the authentication client identifier 169corresponding to the stored client device type identifier and/or clientdevice identifier. The processing unit 4 may be configured to generate atoken key by performing a hash function on the common secret and a tokenvalue (such as a pre-defined arbitrary string or a pre-defined arbitraryvalue). The processing unit 4 may be configured to generate a sessiontoken identifier based on the token key and the session identifier bygenerating a session identifier, and by performing a hash function onthe token key and the session identifier. The processing unit 4 may beconfigured to verify the authentication session token identifier basedon the session token identifier. The processing unit 4 may be configuredto verify the authentication session token identifier by comparing theauthentication session token identifier 167 and the generated sessiontoken identifier. For example, if the processing unit determines thatthe authentication session token identifier 167 matches the generatedsession token identifier, the verification is successful and theprocessing unit 4 may proceed with no user physical intervention, andcontinue to verify the client device data 110 provided in the furtherauthentication message 450. The client device data 100 may comprise aclient device certificate, which may be verified according to thisdisclosure.

In one or more exemplary hearing devices, the hearing device isconfigured to support a special fitting, such as veteran administration,VA, fitting. The memory unit of the hearing device may have stored aspecial indicator indicating the type of special fitting, such as VAfitting.

FIG. 5 schematically illustrates a flowchart of an exemplary method 500of operating a hearing device 2. The hearing device 2 comprises aprocessing unit 4 configured to compensate for hearing loss of a user ofthe hearing device 2, a memory unit 6, and an interface 8. The method500 comprises receiving S1 a connection request for a session via theinterface 8. The connection request may comprise an authentication keyidentifier 166 and/or an authentication type identifier 168, in order toallow the hearing device 2 to perform authentication at this early stagethe connection request and the client device sending the connectionrequest. This may provide a level of access control.

The method 500 comprises obtaining S2 a session identifier 180, e.g.with the hearing device. Obtaining S2 a session identifier 180 maycomprise generating a session identifier 180, such as by generating arandom or pseudo-random number. For example, the processing unit 4generates a random or pseudo-random number of a predetermined length,e.g. 16 bits, 32 bits, 64 bits etc., to be used as a session identifier180. Obtaining S2 a session identifier 180 may comprise retrieving asession identifier 180 from the memory unit. The method 500 may comprisestoring the session identifier 180 in the memory unit 6. For example,storing the session identifier 180 in the memory unit 6 comprisesstoring the session identifier 180 at a memory address of the memoryunit 6, and/or in memory cells of the memory unit 6, such as indesignated memory cells and/or at designated addresses.

The method 500 comprises transmitting S3 via the interface 8 aconnection response comprising a hearing device identifier 112 and thesession identifier 180. Transmitting S3 the connection response maycomprise generating the connection response by including the sessionidentifier 180 and the hearing device identifier 112 and transmittingthe thus generated connection response to e.g. the client device 10.

The method 500 comprises receiving S4, via the interface 8, anauthentication message. The authentication message comprises anauthentication key identifier 166 and client device data 109. The method500 may comprise receiving, via the interface 8, an authenticationmessage 421 from a client device 10. For example the hearing device 2receives the authentication message 421 from the client device 10 inorder to establish a communication session. The client device data 109may comprise a client device certificate, such as unencrypted clientdevice certificate 106 or encrypted client device certificate 106A,fitting data, hearing device operating parameters, and/or firmware data.The authentication key identifier 166 may be an identifier that may beused to verify if the client device 10 has used a client device keyacceptable by the hearing device 2.

The method 500 comprises selecting S5 a hearing device key from aplurality of hearing device keys (e.g. within or amongst a first set ofhearing device keys 115, second set of hearing device keys 116 etc.) inthe memory unit 6 based on the authentication key identifier 166. Whenthe authentication key identifier 166 matches the hearing device keyidentifier, such as a first hearing device key identifier 114 held bythe hearing device 2, the processing unit 4 may be configured to use theauthentication key identifier 166 as a key identifier indicating whichhearing device key is to be used as keying material in the session.Selecting S5 a hearing device key from a plurality of hearing devicekeys in the memory unit may be based on the authentication keyidentifier 166 and/or an authentication type identifier 168. Theauthentication type identifier 168 may be received in plaintext by thehearing device 2 as part of the authentication message 421, and/or asclient device type identifier 156 in the client device certificate 106(encrypted or decrypted). For example, selecting S5 comprises selectinga hearing device key that the authentication key identifier 166 and theauthentication type identifier 168 indicate.

The method 500 comprises verifying S6 the client device data 109 basedon the selected hearing device key and terminating S7 the session ifverification fails. Verifying S6 the client device data 109 based on theselected hearing device key may comprise verifying the integrity of theclient device data 109 based on the selected hearing device key, such asverifying a MAC and/or a digital signature comprised in the clientdevice data 109. Verifying S6 the client device data 109 based on theselected hearing device key may comprise decrypting the client devicedata 109 using the selected hearing device key (as keying material toderive a decryption key or as a decryption key), when the client devicedata 109 is received encrypted. Verifying S6 the client device data 109based on the selected hearing device key may comprise verifying theclient device data 109 by comparing the received client device data 109with data stored in the memory unit. For example, verification fails andthe session is terminated if integrity of the client device data 109 isdetected as corrupted by e.g. verifying a MAC or a digital signature, ifdecryption fails, and/or if comparison of the received client devicedata 109 (when decrypted if the client device data comprises encrypteddata, such as encrypted client device certificate) with data stored inthe memory unit, e.g. hearing device certificate, shows a mismatch or isindicative of corruption.

The authentication message optionally comprises an authentication typeidentifier 168. An authentication type identifier may be indicative of aclient device type identifier 156 and/or a certificate type identifier130, e.g. included in the client device data (encrypted). Selecting S5 ahearing device key from a plurality of hearing device keys may be basedon the authentication type identifier 168. Selecting S5 the hearingdevice key may be based on the authentication type identifier 168 and/orthe authentication key identifier 166 provided in the authenticationmessage 421.

The client device data 109 may comprise a client device certificate 106or an encrypted client device certificate 106A, an authentication keyidentifier 166, and/or an authentication type identifier 168. The method500 may comprise generating S8 a certificate key based on the selectedhearing device key and/or the session identifier 180; and verifying S6the client device data 109 may comprise decrypting the encrypted clientdevice certificate 106A with the certificate key to obtain a decryptedversion 106B of the encrypted client device certificate 106A. Decryptingthe encrypted client device certificate 106A with the certificate keymay comprise decrypting the encrypted client device certificate 106Ausing a certificate key, a common secret and/or a hearing device key,such as generating a certificate key based on a common secret, andprocessing the encrypted client device certificate 106A using adecryption function and a certificate key. The certificate key may bebased on a common secret and/or a certificate value. Generating acertificate key may comprise obtaining or generating the common secretbased on the selected hearing device key. For example, generating thecommon secret based on the hearing device key comprises retrieving thehearing device certificate 100 from the memory unit 6, the hearingdevice certificate 100 comprising the selected hearing device key,and/or retrieving the selected hearing device key from the memory unit6. The method may comprise generating the common secret based on asession identifier 180 and/or the selected hearing device key (e.g. thefirst primary hearing device key 115A). For example, the common secretCS is generated based on a selected hearing device key and a sessionidentifier 180, e.g. as follows:

CS=hash(HD_KEY,S_ID),

where hash is a hash function, HD_KEY is the selected hearing device keyand S_ID is a session identifier 180. The session identifier 180 maycomprise a random or pseudo random number of a defined length. Thecommon secret may be used as a certificate key in one or more exemplarymethods. The method 500 may comprise storing the common secret in thememory unit 6, so as to e.g. retrieve the common secret from the memoryunit 6 when needed.

Generating a certificate key may comprise performing a hash function onthe common secret and/or a certificate value. Generating the certificatekey may be performed e.g. as follows:

C_KEY=hash(CS,C_VAL),

where hash is a hash function, CS is the common secret and C_VAL is acertificate value. The certificate value may be a predefined value orstring, such as the string “certificate”.

In one or more exemplary methods, generating a certificate key comprisesperforming a hash function on the hearing device key (e.g. the firstprimary hearing device key 115A) and the session identifier 180. Stateddifferently, the common secret may be used as a certificate key if theclient device has also used the common secret as certificate key toencrypt the client device certificate 106.

Verifying S6 the client device data 109 may comprise decrypting theencrypted client device certificate 106A using the certificate keygenerated by the hearing device 2 and obtaining the decrypted version106B of the encrypted client device certificate 106A.

In one or more exemplary methods, verifying S6 the client device data109 may comprise verifying a content of the decrypted version 106B ofthe encrypted client device certificate 106A, e.g. based on a hearingdevice certificate or at least parts thereof.

For example, verifying S6 (with the hearing device) the client devicedata 109 comprises determining if the authentication key identifier 166matches a client device key identifier 159 of the client devicecertificate 106, and verification fails if no match is determined.

In one or more exemplary methods, verifying S6 the client device data109 comprises determining if a client device type identifier 156 of theclient device certificate 106 or 106B is valid and verification fails ifthe client device type identifier 156 of the client device certificate106 or 106B is not valid. For example, an authentication type identifier168 is sent in plain text in the authentication message 421, theauthentication type identifier 168 sent in plain text is valid if theauthentication type identifier 168 matches a corresponding client devicetype identifier 156 comprised in the decrypted version 106B of theclient device certificate 106. For example, determining if a clientdevice type identifier 156 of the client device certificate 106 is validcomprises determining if the client device type identifier 156 of theclient device certificate 106 is comprised in a list of authorizedclient devices stored in the memory unit 6 and/or retrieved from remotedata storage.

In one or more exemplary methods, verifying S6 the client device data109 comprises verifying a digital signature 113A of the client devicecertificate 106, 106B, and verification fails if the digital signatureis not verified. For example, the client device data 109 comprises adigital signature 113A included in or appended to the client device data109 to protect integrity of the client device data 109. Verifying adigital signature 113A comprises e.g. computing a comparison resultbased on the digital signature 113A and a corresponding client devicepublic key and comparing the comparison result to the received clientdevice data 109. Verifying a digital signature 113A may compriseretrieving the corresponding client device public key from the memoryunit 6 and/or from remote data storage. The digital signature 113A isverified as valid, or the verification is successful when the digitalsignature 113A raised to the power of the corresponding client devicepublic key is identical to the received client device data 109.

In one or more exemplary methods, the client device certificate 106comprises a signing device identifier 136A and/or a client deviceidentifier 158, and verifying S6 the client device data 109 comprisesdetermining if the signing device identifier 136A and/or the clientdevice identifier 158 of the client device certificate 106 or 106B isvalid and wherein verification fails if the client device identifier 158and/or the signing device identifier 136A is not valid.

In one or more exemplary methods, the method 500 comprises receiving anadditional authentication message 440 comprising client device data 110and an authentication device identifier 169. The method may furthercomprise obtaining, from the memory unit 6, a common secret based on theauthentication device identifier 169, generating an additionalcertificate key from the common secret, and verifying the client devicedata 110 based on the additional certificate key.

In one or more exemplary methods, the method 500 comprises generating anoffline session key based on the common secret and the sessionidentifier 180, and communicating with the client device 10 using theoffline session key.

In one or more exemplary methods, the method 500, the authenticationmessage 421 comprises an authentication token identifier, and the method500 comprises storing the authentication token identifier in the memoryunit 6 and linking the authentication token identifier with the commonsecret.

In one or more exemplary methods, the method 500 comprises receiving afurther authentication message 450 comprising client device data 110, anauthentication type identifier 168, an authentication key identifier 166and/or an authentication session token identifier 167. The method 500may comprise obtaining a common secret based on the authentication typeidentifier 168, generating a token key based on the common secret; andgenerating a session token identifier based on the token key and thesession identifier. The method 500 may comprise verifying theauthentication session token identifier 167 based on the session tokenidentifier.

In one or more exemplary methods, the method 500 comprises generating asession key based on the session identifier 180 and the hearing devicekey, receiving and authenticating session data (e.g. hearing device data430) based on the session key.

Exemplary hearing devices and methods are set out in the followingitems.

Item 1. A hearing device comprising

a processing unit configured to compensate for hearing loss of a user ofthe hearing device;

a memory unit; and

an interface,

wherein the processing unit is configured to:

receive a connection request for a session via the interface;

obtain a session identifier;

transmit, via the interface, a connection response comprising a hearingdevice identifier and the session identifier;

receive, via the interface, an authentication message comprising anauthentication key identifier and client device data;

select a hearing device key from a plurality of hearing device keys inthe memory unit based on the authentication key identifier;

verify the client device data based on the selected hearing device key;and

terminate the session if the verification fails.

Item 2. Hearing device according to item 1, wherein the authenticationmessage comprises an authentication type identifier, and wherein toselect a hearing device key from a plurality of hearing device keys isbased on the authentication type identifier.

Item 3. Hearing device according to any of items 1-2, wherein the clientdevice data comprises an encrypted client device certificate; andwherein the processing unit is configured to generate a certificate keybased on a common secret; and wherein to verify the client device datacomprises to decrypt the encrypted client device certificate with thecertificate key to obtain a decrypted version of the encrypted clientdevice certificate.

Item 4. Hearing device according to item 3, wherein the common secret isbased on the selected hearing device key and/or the session identifier.

Item 5. Hearing device according to any of items 3-4, wherein to verifythe client device data comprises to determine if the authentication keyidentifier matches a client device key identifier of the client devicecertificate, and wherein verification fails if no match is determined.

Item 6. Hearing device according to any of items 3-5, wherein to verifythe client device data comprises to determine if a client device typeidentifier of the client device certificate is valid and whereinverification fails if the client device type identifier of the clientdevice certificate is not valid.

Item 7. Hearing device according to any of items 3-6, wherein to verifythe client device data comprises to verify a digital signature of theclient device certificate, and wherein verification fails if the digitalsignature is not verified.

Item 8. Hearing device according to any of items 3-7, wherein the clientdevice certificate comprises a signing device identifier and/or a clientdevice identifier, and wherein to verify the client device datacomprises to determine if the signing device identifier and/or theclient device identifier is valid and wherein verification fails if theclient device identifier of the client device and/or the signing deviceidentifier is not valid.

Item 9. Hearing device according to any of items 3-8, wherein theprocessing unit is configured to receive an additional authenticationmessage comprising client device data and an authentication deviceidentifier, wherein the processing unit is configured to

obtain, from the memory unit, the common secret based on theauthentication device identifier;

generate an additional certificate key from the common secret; and

verify the client device data based on the additional certificate key.

Item 10. Hearing device according to item 9, wherein the processing unitis configured to generate an offline session key based on the commonsecret and the session identifier, and wherein the processing unit isconfigured to communicate with the client device using the offlinesession key.

Item 11. Hearing device according to any of items 3-10, wherein theauthentication message comprises an authentication token identifier, andwherein the processing unit is configured to store the authenticationtoken identifier in the memory unit and to link the authentication tokenidentifier with the common secret.

Item 12. Hearing device according to any of items 3-11, wherein theprocessing unit is configured to receive further authentication messagecomprising client device data, an authentication type identifier, anauthentication key identifier and/or an authentication session tokenidentifier, wherein the processing unit is configured to

obtain a common secret based on the authentication type identifier;

generate a token key based on the common secret;

generate a session token identifier based on the token key and thesession identifier; and

verify the authentication session token identifier based on the sessiontoken identifier.

Item 13. Hearing device according to any of items 1-12, wherein theprocessing unit is configured to generate a session key based on thesession identifier and the hearing device key, and wherein theprocessing unit is configured to receive and authenticate session databased on the session key.

Item 14. Method of operating a hearing device comprising a processingunit configured to compensate for hearing loss of a user of the hearingdevice; a memory unit; and an interface, the method comprising

receiving a connection request for a session via the interface;

obtaining a session identifier;

transmitting, via the interface, a connection response comprising ahearing device identifier and the session identifier;

receiving, via the interface, an authentication message comprising anauthentication key identifier and client device data;

selecting a hearing device key from a plurality of hearing device keysbased on the authentication key identifier;

verifying the client device data based on the selected hearing devicekey; and

terminating the session if verification fails.

Item 15. Method according to item 14, wherein the authentication messagecomprises a authentication type identifier, and wherein selecting ahearing device key from a plurality of hearing device keys is based onthe authentication type identifier.

Item 16. Method according to any of items 14-15, wherein the clientdevice data comprises an encrypted client device certificate, andwherein the method comprises generating a certificate key based on theselected hearing device key and/or the session identifier; and whereinverifying the client device data comprises decrypting the encryptedclient device certificate with the certificate key.

Item 17. Method according to any of items 14-16, wherein verifying theclient device data comprises verifying a digital signature of the clientdevice certificate, and wherein verification fails if the digitalsignature is not verified.

The use of the terms “first”, “second”, and the like does not imply anyparticular order, but they are included to identify individual elements.Moreover, the use of the terms first, second, etc. does not denote anyorder or importance, but rather the terms first, second, etc. are usedto distinguish one element from another. Note that the words first andsecond are used here and elsewhere for labelling purposes only and arenot intended to denote any specific spatial or temporal ordering.Furthermore, the labelling of a first element does not imply thepresence of a second element.

Although particular features have been shown and described, it will beunderstood that they are not intended to limit the claimed invention,and it will be made obvious to those skilled in the art that variouschanges and modifications may be made without departing from the spiritand scope of the claimed invention. The specification and drawings are,accordingly to be regarded in an illustrative rather than restrictivesense. The claimed invention is intended to cover all alternatives,modifications and equivalents.

LIST OF REFERENCES

-   -   1 system    -   2 hearing device    -   4 processing unit    -   5 microphone    -   6 memory unit    -   7 receiver    -   8 interface    -   10 client device    -   12 manufacturing device    -   14 fitting device    -   16 server device    -   21 communication link between client device and hearing device    -   22 communication link between server device and manufacturing        device    -   23 communication link between hearing device and manufacturing        device    -   24 communication link between server device and client        device/fitting device    -   100 hearing device certificate    -   106 client device certificate    -   106A encrypted client device certificate    -   106B decrypted version of encrypted client device certificate    -   109 client device data    -   110 client device data in additional/further authentication        message    -   112 hearing device identifier    -   113A digital signature of the client device certificate    -   113B digital signature of the hearing device certificate    -   114 first hearing device key identifier    -   115 first set of hearing device keys    -   115A first primary hearing device key    -   115B first secondary hearing device key    -   115C first tertiary hearing device key    -   115D first quaternary hearing device key    -   116 second hearing device key identifier    -   117 second set of hearing device keys    -   117A second primary hearing device key    -   117B second secondary hearing device key    -   117C second tertiary hearing device key    -   117D second quaternary hearing device key    -   130A certificate type identifier of the client device        certificate    -   130B certificate type identifier of the hearing device        certificate    -   132 version identifier    -   134 length identifier    -   136A signing device identifier of the client device certificate    -   136B signing device identifier of the hearing device certificate    -   138 hardware platform identifier    -   140 software platform identifier    -   142 certificate timestamp    -   144 client device type authorization identifier    -   146 token parameter    -   148A first hardware identifier of the client device certificate    -   148B first hardware identifier of the hearing device certificate    -   150 second hardware identifier of the client device certificate    -   156 client device type identifier    -   158 client device identifier    -   159 client device key identifier    -   160 Bluetooth address    -   166 authentication key identifier    -   167 authentication session token identifier    -   168 authentication type identifier    -   169 authentication device identifier    -   180 session identifier    -   400 signaling diagram    -   410/411 connection request    -   412 connection response    -   420/421 authentication message    -   422 authentication response    -   430 hearing device data    -   440 additional authentication message    -   450 further authentication message    -   500 exemplary methods

1. A hearing device comprising: a processing unit configured tocompensate for hearing loss of a user of the hearing device; a memoryunit; and an interface; wherein the processing unit is configured to:receive a connection request for a session via the interface; obtain asession identifier; transmit, via the interface, a connection responsecomprising a hearing device identifier and the session identifier;receive, via the interface, an authentication message comprising anauthentication key identifier and client device data; select a hearingdevice key from a plurality of hearing device keys in the memory unitbased on the authentication key identifier; and verify the client devicedata based on the selected hearing device key.
 2. The hearing device ofclaim 1, wherein the session identifier is for a session, and whereinthe processing unit is configured to terminate the session if averification of the client device data fails.
 3. The hearing deviceaccording to claim 1, wherein the authentication message comprises anauthentication type identifier, and wherein the processing unit isconfigured to select the hearing device key from the plurality ofhearing device keys based on the authentication type identifier.
 4. Thehearing device according to claim 1, wherein the client device datacomprises an encrypted client device certificate; wherein the processingunit is configured to generate a certificate key based on a commonsecret; and wherein the processing unit is configured to verify theclient device data by decrypting the encrypted client device certificatewith the certificate key to obtain a decrypted version of the encryptedclient device certificate.
 5. The hearing device according to claim 4,wherein the common secret is based on the selected hearing device keyand/or the session identifier.
 6. The hearing device according to claim4, wherein the processing unit is configured to verify the client devicedata by determining whether the authentication key identifier matches aclient device key identifier of the client device certificate.
 7. Thehearing device according to claim 4, wherein the processing unit isconfigured to verify the client device data by determining whether aclient device type identifier of the client device certificate is valid.8. The hearing device according to claim 4, wherein the processing unitis configured to verify the client device data by verifying a digitalsignature of the client device certificate.
 9. The hearing deviceaccording to claim 4, wherein the client device certificate comprises asigning device identifier and/or a client device identifier, and whereinthe processing unit is configured to verify the client device data bydetermining whether the signing device identifier and/or the clientdevice identifier is valid.
 10. The hearing device according to claim 1,wherein the processing unit is configured to generate a session keybased on the session identifier and the hearing device key, and whereinthe processing unit is configured to receive and authenticate sessiondata based on the session key.
 11. A method of operating a hearingdevice comprising a processing unit configured to compensate for hearingloss of a user of the hearing device, a memory unit, and an interface,the method comprising: receiving a connection request for a session viathe interface; obtaining a session identifier; transmitting, via theinterface, a connection response comprising a hearing device identifierand the session identifier; receiving, via the interface, anauthentication message comprising an authentication key identifier andclient device data; selecting a hearing device key from a plurality ofhearing device keys based on the authentication key identifier; andverifying the client device data based on the selected hearing devicekey.